import MyNavBar from '../../components/navbar'
import { Tabs } from 'antd-mobile'
import QRCode from 'react-qr-code'
import CodeLogin from './components/CodeLogin'
import styles from './css/login.module.css'

function Login() {
  return (
    <div className={styles.box}>
      <MyNavBar title="登录" />

      {/* 绘制登录的 tab 栏和表单 */}
      <Tabs>
        <Tabs.Tab
          title="验证码登录"
          key="fruits"
        >
          <CodeLogin />
        </Tabs.Tab>
        <Tabs.Tab
          title="密码登录"
          key="vegetables"
        >
          西红柿
        </Tabs.Tab>
        <Tabs.Tab
          title="扫码登录"
          key="animals"
        >
          <QRCode value="https://escook.cn" />
        </Tabs.Tab>
      </Tabs>
    </div>
  )
}

export default Login
